package com.huike.controller.system;

import com.huike.pojo.SysDept;
import com.huike.pojo.SysPost;
import com.huike.result.Result;
import com.huike.service.system.PostSystemService;
import com.huike.vo.SysPostVO;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/system/post")
@Slf4j
public class PostSystemController {
    @Autowired
    private PostSystemService postSystemService;


    @GetMapping("/list")
    public Result list(SysPost post) {
        log.info("获取部门列表：{}", post);
        List<SysPost> depts = postSystemService.selectDeptList(post);
        return Result.success(depts);
    }
}
